package cn.liberals.basic.query;

import lombok.Data;

/**
* @Description: TODO
* @Author: liberals
* @Version: 1.0
* @Date:  2022/6/21 21:44  
*/
@Data
public class BaseQuery {

    // 1.当前页码
    private Integer currentPage  = 1;

    // 2.当前页展示条数
    private Integer pageSize = 5;

    // 添加部门高级查询关键字
    private String keyword;

    /**
     * 计算分页起始位置
     * @return
     */
    public Integer getStart(){
        return (this.currentPage - 1) * this.pageSize;
    }

}
